package org.wh1tew0lf.vframe.framework;

import java.util.ArrayList;

import org.wh1tew0lf.vframe.model.datamodel.IDataModel;
import org.wh1tew0lf.vframe.model.datamodel.IReadonlyDataModel;

public interface ICache {
	public IReadonlyDataModel loadByIdForRead(int id);
	public IDataModel loadByIdForEdit(int id, String lockKey);
	public IReadonlyDataModel saveNew(IReadonlyDataModel newData);
	public IReadonlyDataModel saveChanges(IReadonlyDataModel modifiedData);
	public boolean removeById(int id);
	public int updateQueryStructure(VDatabaseQueryStructure dqs);
	public ArrayList<IReadonlyDataModel> doQuery(int queryId, int startRecordNumber, int endRecordNumber);
}
